package server.business.task;

import com.core.initialize.Message;

import server.ScriptEnum;
import server.ServerTransportProxy;
import server.commonData.User;
import server.messageId.S2CMessageId;


public class TaskScript implements ITaskScript
{
	
	/* (non-Javadoc)
	 * @see server.business.task.ITaskScript#refreshTaskListClient(server.commonData.User)
	 */
	@Override
	public void refreshTaskListClient(User user)
	{
		Message msg = Message.newMessage();
		msg.setModuleAction(S2CMessageId.Task.MODULE_ID,S2CMessageId.Task.TASK_LIST_RES);
		msg.setBody(user.getTaskList().showClient(user));
		ServerTransportProxy.sendMsg(msg, user);
	}

	@Override
	public int getId() {
		return ScriptEnum.TASK_SCRIPT;
	}

}
